import request from '@/utils/request'

// 查询报损记录列表
export function listLosses(query) {
  return request({
    url: '/procurement-system/losses/list',
    method: 'get',
    params: query
  })
}

// 查询报损记录详细
export function getLosses(id) {
  return request({
    url: '/procurement-system/losses/' + id,
    method: 'get'
  })
}

// 新增报损记录
export function addLosses(data) {
  return request({
    url: '/procurement-system/losses',
    method: 'post',
    data: data
  })
}

// 修改报损记录
export function updateLosses(data) {
  return request({
    url: '/procurement-system/losses',
    method: 'put',
    data: data
  })
}

// 删除报损记录
export function delLosses(id) {
  return request({
    url: '/procurement-system/losses/' + id,
    method: 'delete'
  })
}
